﻿@model IRIS.Models.IEContentsIECategoriesCategoryViewModel

@{
    ViewBag.Title = "Groups";
}
@section SubMenu
{
    <ul id="submenu">
    @foreach (var item in Model.m_Categories)
    { 
        <li>@Html.ActionLink(item.Name, "Groups", new { id = item.ID })</li>
    }
    </ul>
}

<h2>@Model.m_ContentCategory.Name</h2>

@if(Model.m_Contents.Count() > 0)
{
    foreach (var item in Model.m_Contents) 
    { 
            <div class="news">
               <h2>@Html.ActionLink(item.ContentTitle, "Details", new { id = item.ID })<span class="contentdate">@{ var date = item.Created.ToShortDateString();}@date</span></h2>
               <h3><b>Höfundur:</b> @item.Author</h3>
                <span><b>Flokkur: </b>@item.ContentCategory.Name</span>
                <h6>Stutt Lýsing:</h6>
               <p> @{ var segment = item.Description; } 
                    @Html.Raw(segment)</p>
           </div>
    }
}
else
{
    <p>Engar greinar eru í þessum flokk.</p>
}

